package com.acousticpayment.acoustic_comm;


import android.os.Bundle;
import android.os.Handler;
import android.app.Activity;
import android.view.Menu;
import android.view.MotionEvent;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.View.OnTouchListener;
import android.widget.Button;
import android.widget.EditText;
import android.widget.TextView;

public class MainActivity extends Activity implements OnClickListener, OnTouchListener
{
	EditText etSend = null;
	EditText etReceive = null;
	TextView tvLog = null;
	Button btSend = null;
	Button btReceive = null;
	@Override
	protected void onCreate(Bundle savedInstanceState)
	{
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_main);
		etSend = (EditText) findViewById(R.id.etSend);
		etReceive = (EditText) findViewById(R.id.etReceive);
		btSend = (Button) findViewById(R.id.btSend);
		btReceive = (Button) findViewById(R.id.btReceive);
		tvLog = (TextView) findViewById(R.id.tvLog);
		btSend.setOnClickListener(this);
		btReceive.setOnClickListener(this);
	}
	Handler handler = new Handler();
	@Override
	public boolean onCreateOptionsMenu(Menu menu)
	{
		// Inflate the menu; this adds items to the action bar if it is present.
		getMenuInflater().inflate(R.menu.activity_main, menu);
		return true;
	}

	@Override
	public void onClick(View v)
	{
		// TODO Auto-generated method stub
		switch (v.getId())
		{
			case R.id.btSend:
			{
				tvLog.setText("sending...");
			}break;
			case R.id.btReceive:
			{
				tvLog.setText("receiving...");
			}break;
			default:
			{
				
				
			}break;
		}
	}
	@Override
	public boolean onTouch(View arg0, MotionEvent arg1)
	{
		// TODO Auto-generated method stub
		
		return false;
	}
}
